﻿using IconYuan.Model.Entity.Users;
using System;

namespace IconYuan.Model.DTO.Users
{
    public class ListParamDto
    {
        public int page { get; set; } = 1;
        public string mobile { get; set; } = string.Empty;

    }
    public class UserInfoDto
    {
        public UserBase userInfo { get; set; }
        public UserDetail userDetail { get; set; }
        public UserGradeDto gradeInfo { get; set; }
    }

    /// <summary>
    /// 用户等级
    /// </summary>
    public class UserGradeDto
    {
      public int  grade_id { get; set; }
        public string name { get; set; }
        public string nick_name { get; set; }
        public DateTime start_time { get; set; }
        public DateTime end_time { get; set; }
        public string upgrade { get; set; }
    }

    ///// <summary>
    ///// 用户视图
    ///// </summary>
    //public class UserDto : User
    //{
    //    /// <summary>
    //    /// 默认收货地址ID
    //    /// </summary>
    //    public int address_id { get; set; }

    //    /// <summary>
    //    /// 会员等级
    //    /// </summary>
    //    public string grade { get; set; }
    //    /// <summary>
    //    /// 头像
    //    /// </summary>
    //    public string avatar_url { get; set; } = string.Empty;

    //    /// <summary>
    //    /// 最后登录时间戳
    //    /// </summary>
    //    public int last_login_time
    //    {
    //        get
    //        {
    //            return (int)(last_time - TimeZone.CurrentTimeZone.ToLocalTime(new DateTime(1970, 1, 1))).TotalSeconds;
    //        }
    //    }
    //}
}
